﻿using System.Collections.Generic;
using System.Linq;
using Atha.Contracts;

namespace Atha.Languages
{
	public sealed class TestRunResultBuilder : ITestRunResultBuilder
	{
		private List<ITestRunTestResult> _results;

		public TestRunResultBuilder()
		{
			this._results = new List<ITestRunTestResult>();
		}

		public IEnumerable<ITestRunTestResult> Results { get { return this._results.AsEnumerable(); } }

		public ITestRunResultBuilder AddResult(ITestRunTestResult testRunTestResult)
		{
			this._results.Add(testRunTestResult);

			return this;
		}
	}
}